package com.pheruagor.handmanager.model.business.activity {

    /**
     * Use as abstract class for all activities made by club members
     */
    public class Activity {

        //-----------------------------------------------------
        // Properties
        //-----------------------------------------------------
        private var m_id:String;
        private var m_memberId:String;
        private var m_beginDate:Date;
        private var m_endDate:Date;
        private var m_description:String;

        /**
         * Constructor
         */
        public function Activity() {
        }

        /**
         * Member ID
         */
        public function get id():String {
            return m_id;
        }

        /**
         * @private
         */
        public function set id(value:String):void {
            m_id = value;
        }

        /**
         * Member id
         */
        public function get memberId():String {
            return m_memberId;
        }

        /**
         * @private
         */
        public function set memberId(value:String):void {
            m_memberId = value;
        }

        /**
         * begin date of activity
         */
        public function get beginDate():Date {
            return m_beginDate;
        }

        /**
         * @private
         */
        public function set beginDate(value:Date):void {
            m_beginDate = value;
        }

        /**
         * end date of activity
         */
        public function get endDate():Date {
            return m_endDate;
        }

        /**
         * @private
         */
        public function set endDate(value:Date):void {
            m_endDate = value;
        }

        /**
         * activityName of activity
         */
        public function get name():String {
            return null;
        }

        /**
         * description String of activity
         */
        public function get description():String {
            return m_description;
        }

        /**
         * @private
         */
        public function set description(value:String):void {
            m_description = value;
        }

        //-----------------------------------------------------
        // Operation
        //-----------------------------------------------------
        public function clone():Activity {
            var result:Activity = new Activity();
            result.id = id;
            result.beginDate = new Date(m_beginDate);
            result.endDate = new Date(m_endDate);
            result.description = m_description;

            return result;
        }
    }
}